<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>vue组件</title>
</head>
<body>
    <div id="app">
        <ol>
            <todo></todo>
            <todo></todo>
        </ol>
    </div>
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<script>
    Vue.component('todo',{
        template:'<li>吃饭</li>'
    })

    var app = new Vue({
        el:"#app"
    })
</script>
</body>
</html>